<!--
**********************************************************
* @Author: 张小平
* @Date:   2024-05-01
* @Email:  qqshuqian@163.com
* @Last modified: 最后修改日期
* @Description: 文件描述
**********************************************************
-->
<template>
    <div class="user">
        <basic-container>
            <avue-crud
                    v-model="form"
                    v-model:page="page"
                    v-model:search="searchForm"
                    :permission="getPermission"
                    v-bind="bindVal"
                    v-on="onEvent"
                    :option="option"
                    :data="tableData"

            >
                <template #menu-left="{size}">
<!--                    <el-button type="primary" @click="importShowHandle()">导入</el-button>-->
                    <el-button type="primary" @click="exportHandle()">导出</el-button>
                </template>
            </avue-crud>

        </basic-container>

    </div>
</template>

<script>
    import curdMixin from '@/framework-core/mixins/crud';
    import {tableOption} from "./index";

    export default {
        name: "sys_static_picture",
        mixins: [curdMixin],
        data() {
            return {
                pageConfig:{name:"静态图片","url":"picture",permissionConfig:"sys_sysstaticpicture"},
                searchForm: {},
                loading: false,
                form:{},
                option: tableOption
            };
        },
        computed: {
            ...mapState({
                permissions: (state) =>state.user.permission,
            })

        },
        created() {
            this.init();
        },
        methods: {
            init() {
            },
            saveBefor(data){
                if(data.pictureUrl){
                    data.picture = data.pictureUrl;
                }
            },
            getPermission: function (key, row, index) {
                return this.getCommPermission(key, row, index);
            },

        }
    };
</script>
<style lang="scss">

</style>
